package com.caine.proxy.cglib;

import net.sf.cglib.MethodInterceptor;
import net.sf.cglib.MethodProxy;

import java.lang.reflect.Method;

/**
 * @Author: CaineZhu
 * @Description:
 * @Date: Created in 17:03 2020/11/4
 * @Modified By:
 */
public class CglibMethodInterceptor implements MethodInterceptor {
    @Override
    public Object intercept(Object o, Method method, Object[] objects, MethodProxy methodProxy) throws Throwable {
        System.out.println("method = " + method);
        return methodProxy.invokeSuper(o, objects);
    }
}
